<include file="Public/header"/>
<div class="col-sm-9 col-sm-offset-3 col-md-10 col-md-offset-2 main">
<h1 class="item">社团成员列表</h1>
<table border  width="80%" class="table table-striped table-bordered table-hover">

<?php 
$con =mysql_connect('localhost','root','');
if (!$con) {
    die('数据库不存在'.mysql_errno());
}
mysql_set_charset('utf8');
//设置字符集
$db=mysql_select_db('study',$con);
$sql='select * from groups where gid='.$_GET['id'];
        $result=mysql_query($sql,$con); 
        while ($row=mysql_fetch_assoc($result)) 
        {
            echo'<h3>社团名称：'.$row['groupname'].'</h3>';
        }
?>
<table border  width="80%" class="table table-striped table-bordered table-hover">
<tr>
	<th>用户名</th>
	<th>学号</th>
	<th>状态</th>
	<th>操作</th>
</tr>
<volist name="members" id="vo">
<tr>
	<td>{$vo.username}</td>
	<td>{$vo.stunum}</td>
	<td>
	   <if condition="$vo.state eq  0">待审批
	   <elseif  condition="$vo.state  eq 1"/>普通成员
	   <else />负责人</if>
   </td>
<td>
<ul>
      <if condition="$vo.state eq  0"><li><a href="setGroupUser?id={$vo.id}"><i class="icon-envelope"></i>审批通过</a></li>
      <else/><li><a href="setGroupAdmin?id={$vo.id}"><i class="icon-envelope"></i>设置为负责人</a></li></if>
       <li><a href="delGroupUser?id={$vo.id}"><i class="icon-edit"></i>删除</a></li>
 </ul>   </div>
</td>
</tr>
</volist>
</table>
<div class="pagination">
	{$page}
</div>
<include file="Public/footer"/>